#include <iostream>

using namespace std;

void tongji(void);

int main(void)
{
	tongji();

	return 0;
}

void tongji(void)
{
	int num = 1;
	int i = 0;
	int sumj = 0, sumo = 0;

	while(num != 0)
        {
                cout << "num" << i + 1 << ": ";
                cin >> num;
                if(num % 2 == 1)
                        sumj += num;
                if(num % 2 == 0)
                        sumo += num;
		i ++;
        }
	cout << "奇数：" << sumj << endl;
	cout << "偶数：" << sumo << endl;
}
